Skip to content

Plot improvements: subplot_tracer_from_fit overhaul, line_colors, caustics#408

Merged
Jammy2211 merged 1 commit intomainfrom
feature/plot-improvements-4
Mar 26, 2026
Merged

Plot improvements: subplot_tracer_from_fit overhaul, line_colors, caustics#408
Jammy2211 merged 1 commit intomainfrom
feature/plot-improvements-4

Conversation

@Jammy2211
Copy link
Copy Markdown
Collaborator

Summary

  • subplot_tracer_from_fit: compute critical curves and caustics before drawing any panels so panels 0–2 (Model Image, Source Model Image, Source Plane) all receive line overlays; add Deflections Y/X and Magnification to panels 6–8; use lens_galaxies.deflections_yx_2d_from matching galaxies.png
  • subplot_tracer: add critical curves (black=tangential, white=radial) and caustics to all relevant panels; harden source image and source plane panels with source_vmax scaling
  • _plot_source_plane: log exceptions via logger.warning instead of silently blanking the axis — makes failures visible in logs
  • plotter.py: remove redundant standalone subplot_tracer call from the tracer plotter (imaging plotter handles subplot_tracer via subplot_tracer_from_fit)

Test plan

  • Run a fit with a pixelization source and verify tracer.png shows the correct Source Model Image (non-blank) in panel 1
  • Verify Source Plane (No Zoom) shows the inversion reconstruction in panel 2
  • Verify critical curves overlay Model Image and Source Model Image panels
  • Verify caustics overlay the Source Plane panel
  • Verify Deflections Y/X and Magnification appear in panels 6–8
  • Check logs for any Could not plot source reconstruction warnings if panels still blank

🤖 Generated with Claude Code

…stics

- subplot_tracer_from_fit: compute critical curves and caustics before drawing panels
  so all source panels receive line overlays; add deflections Y/X and magnification
  to panels 6-8; use lens_galaxies.deflections_yx_2d_from for correct panel content
- subplot_tracer: add critical curves (black=tangential, white=radial) and caustics;
  harden source image and source plane panels; add source_vmax scaling
- _plot_source_plane: log exceptions instead of silently blanking the axis
- plotter.py: remove standalone subplot_tracer call from tracer plotter (imaging
  plotter handles subplot_tracer via subplot_tracer_from_fit)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Jammy2211 Jammy2211 merged commit f113fdb into main Mar 26, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant